﻿// HSS.Interlink.Web.IDownloadHandler.cs
// ----------------------------------------------------------------------------
// Licensed under the MIT license (http://www.opensource.org/licenses/mit-license.html)
// ----------------------------------------------------------------------------
// HighSpeed-Solutions, LLC
// Copyright (c) 2001-2012
// ----------------------------------------------------------------------------
// File:       IDownloadHandler.cs
// Author:     HSS\gbanta
// Created:    07/16/2011
// Modified:   12/16/2011
// ----------------------------------------------------------------------------
namespace HSS.Interlink.Web
{
	/// <summary>
	/// An interface that can be implemented to handle download requests.
	/// </summary>
	public interface IDownloadHandler : IFileTransmit
	{
		/// <summary>
		/// Perform the download operation.
		/// </summary>
		/// <param name="context">The current HttpContext</param>
		/// <param name="fileQuery">The currently parsed QueryString</param>
		void Download(System.Web.HttpContext context, FileQuery fileQuery);

		/// <summary>
		/// Perform the open operation with a Content-Disposition of 'Inline'.
		/// </summary>
		/// <param name="context">The current HttpContext</param>
		/// <param name="fileQuery">The currently parsed QueryString</param>
		void OpenInline(System.Web.HttpContext context, FileQuery fileQuery);

		/// <summary>
		/// Perform the open operation with a Content-Disposition of 'Attachment'.
		/// </summary>
		/// <param name="context">The current HttpContext</param>
		/// <param name="fileQuery">The currently parsed QueryString</param>
		void OpenAsAttachment(System.Web.HttpContext context, FileQuery fileQuery);
	}
}